package com.data.modules.feign;

import com.data.common.api.vo.CrmResult;
import com.data.modules.emp.entity.AdminUserBo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @Description
 * @Date 2022-2-22 10:43:47
 * @Author chj
 */
@Component
@FeignClient(name = "admin", url = "${crm.admin-url:}",contextId = "adminUser")
public interface AdminUserService {

    /**
     * 查询用户信息
     *
     * @return
     */
    @PostMapping(value = "/adminUser/queryUserInfo")
    CrmResult<AdminUserBo> queryUserInfo(@RequestParam("userId") Long userId);

    /**
     * 查询用户信息
     *
     * @return
     */
    @PostMapping(value = "/adminUser/queryUserByIds")
    CrmResult<List<AdminUserBo>> queryUserByIds(@RequestBody List<Long> ids);

}
